const modules = {}
 
// Vite's dynamic import (replaces require.context) 
const files = import.meta.glob('./*.js',  { eager: true })
 
for (const path in files) {
  if (path === './index.js')  continue 
  const name = path.replace(/(\.\/ |\.js)/g, '')
  modules[name] = files[path].default 
}
 
export default modules 